package com.yeskery.boot.log.record.starter.core;

/**
 * 业务方法执行结果
 * @author dushuangjiang
 * @date 2021-11-16 17:33
 */
public class MethodExecuteResult {

    /** 执行是否成功 */
    private boolean success;

    /** 是否抛出异常 */
    private Throwable throwable;

    /** 抛出异常的错误信息 */
    private String errorMsg;

    public MethodExecuteResult(boolean success, Throwable throwable, String errorMsg) {
        this.success = success;
        this.throwable = throwable;
        this.errorMsg = errorMsg;
    }

    public boolean isSuccess() {
        return success;
    }

    public void setSuccess(boolean success) {
        this.success = success;
    }

    public Throwable getThrowable() {
        return throwable;
    }

    public void setThrowable(Throwable throwable) {
        this.throwable = throwable;
    }

    public String getErrorMsg() {
        return errorMsg;
    }

    public void setErrorMsg(String errorMsg) {
        this.errorMsg = errorMsg;
    }
}
